package com.aspose.cells;

class zbot implements zahz {
   private boolean a = false;
   private boolean b = false;
   private boolean c;

   public zbot(boolean var1) {
      this.c = var1;
      this.b = var1;
   }

   public zagu a() {
      if (!this.a) {
         return zzg.a;
      } else {
         return this.b ? zyx.a : zyw.a;
      }
   }

   public boolean a(zagu var1, boolean var2) {
      return var2 && var1.b() == 12;
   }

   public zagu a(zagu var1, zaay var2, boolean var3) {
      if (var1 != null) {
         var1 = var1.e(var2);
      }

      if (var1 == null) {
         if (var3) {
            return zyw.a;
         } else {
            this.a(false);
            return zyw.a;
         }
      } else {
         switch(var1.b()) {
         case 0:
            return var1;
         case 1:
            this.a(((zyv)var1).k());
            return zyw.a;
         case 2:
         default:
            if (var3) {
               return zyw.a;
            } else {
               zyv var4 = var1.j(var2);
               if (var4 == null) {
                  return zzg.a;
               }

               this.a(var4.k());
               return zyw.a;
            }
         case 3:
            this.a(((zyy)var1).k() != 0.0D);
            return zyw.a;
         }
      }
   }

   public zagu a(zagu var1, zaay var2, boolean var3, int var4) {
      return this.a(var1, var2, var3);
   }

   private void a(boolean var1) {
      this.a = true;
      if (this.c) {
         if (!var1) {
            this.b = false;
         }
      } else if (var1) {
         this.b = true;
      }

   }
}
